package com.coocaa.ops.admin.v1.homepage.service.impl;

import com.coocaa.ops.admin.v1.homepage.provider.IHomepageInfoQueryProvider;
import com.coocaa.ops.admin.v1.homepage.service.IHomepageInfoQueryService;
import com.coocaa.ops.common.core.biz.homepage.entity.HomepageInfoEntity;
import com.coocaa.ops.admin.v1.homepage.model.HomepageInfoModel;

import com.coocaa.ops.common.core.base.model.PageResultModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author bjh
 * @description 首页信息原始表-查询service接口实现
 * @date : 2020-06-15 16:31:15
 */
@Service
public class HomepageInfoQueryServiceImpl implements IHomepageInfoQueryService {
    @Autowired
    private IHomepageInfoQueryProvider thisQueryProvider;

    /**
     * 获取详情信息
     *
     * @param id
     * @param version
     * @return
     */
    @Override
    public HomepageInfoEntity getDetailInfo(Integer id, Integer version) {
        HomepageInfoEntity entity = thisQueryProvider.getDetailInfo(id, version);
        return entity;

    }

    /**
     * 分页数据-菜单自己使用
     *
     * @param model
     * @return
     */
    @Override
    public PageResultModel<HomepageInfoEntity> pageList(HomepageInfoModel model) {
        PageResultModel<HomepageInfoEntity> pageResultModel = thisQueryProvider.pageList(model);
        return pageResultModel;

    }


    /**
     * 分页数据-其他处选择
     *
     * @param model
     * @return
     */
    @Override
    public PageResultModel<HomepageInfoEntity> dataList(HomepageInfoModel model) {
        PageResultModel<HomepageInfoEntity> pageResultModel = thisQueryProvider.dataList(model);
        return pageResultModel;

    }


}
